This crate implements a straightforward timer to conveniently time code blocks.
usealeo_std::prelude::*;fnfoo()->u32{// Start the timer.
let timer =timer!("Arithmetic");// Insert expensive operation
let x =1+1;// Print the elapsed time up to this point.
lap!(timer);// Insert expensive operation
let y =1+1;// Print the total time elapsed.
finish!(timer);
x + y
}